<template>
    <div id="yuqingwenda">
        <div class="wenda-title">二、模拟问题及应对口径<br></div>
        <div v-if="qusans.length !==0">
            <div  v-for="(item,index) in qusans" :key="index">
                <br>
                <el-divider content-position="left"><i class="el-icon-question"></i></el-divider>
                <div class="question">
                    <span>{{item.type}}.({{item.idx}})</span>
                    <span v-html="item.question"></span>
                </div>
                <br>

                <div class="answer">
                    <span></span>
                    <div v-html="$options.filters.br2p(item.answer)"></div>
                </div>

            </div>
        </div>

        <div v-else>无对应检索结果</div>
    </div>
</template>

<script>
    export default {
        name: "yuqingwenda",
        data(){
          return{

          }
        },
        props:{
            qusans:{
                type:Array,
                default(){
                    return []
                }
            }
        },
        mounted() {
            // console.log(this.qusans);


        },
        filters:{
            br2p(value){
                return  "&emsp;&emsp;" + value.replace(new RegExp("<br>","g"),"<br>&emsp;&emsp;")
            }
        }

    }
</script>

<style scoped>
    #yuqingwenda{
        margin: 5px;
        padding: 5px;
        font-family: FangSong;
    }

    .answer{
        border: 1px dotted blue;
    }

    .answer >>>b {
        color: red;
    }

    .answer >>>strong
    {
        color:greenyellow;
        background-color: #333333;
    }

    .el-icon-question{
        color: aqua;

    }

    .wenda-title{
        font-size: 0.1rem;
        font-weight: bold;
        font-family: FangSong;

    }


</style>